//
// Project Wok
//
// Copyright IBM Corp, 2015-2016
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//

// Overriding Bootstrap styles

.form-group {
    font-size: 1em;
}

label {
    font-size: 1.143em;
    font-weight: 400;
    font-family: $font-family-base;
}

// Form feedback classes

.form-control-feedback {
    display: none;
    width: 16px;
    height: 16px;
}

.has-feedback label ~ .form-control-feedback {
    display: block;
    top: 43px;
    margin-right: 10px;
}

.has-feedback .form-control {
    padding-right: 12px;
}

.has-warning.has-feedback form-control,
.has-error.has-feedback .form-control {
    padding-right: 42.5px;
}

.has-feedback .form-control-feedback {
  display: none;
}

.has-warning.has-feedback .form-control-feedback,
.has-error.has-feedback .form-control-feedback {
    display: block;
    right: 5px;
}

.has-loading .form-control-feedback.wok-loading-icon {
    display:  block;
    margin-right: 10px;
    top: 41px;
    height: 19px;
    width: 19px;
    margin-right: 10px;
}

// Custom check-boxes and radios
input[type=checkbox].wok-checkbox,
input[type=radio].wok-radio {
    opacity: 0;
    position: absolute;
    top: 0;
}

input[type=checkbox].wok-checkbox + label:before,
input[type=radio].wok-radio + label:before {
    font-family: FontAwesome;
    display: inline-block;
}

input[type=checkbox].wok-checkbox + label:before {
    content: "\f096";
    letter-spacing: 10px;
}

input[type=checkbox].wok-checkbox:checked + label:before {
    content: "\f14a";
    letter-spacing: 8px;
    margin-right: 0.9px // Sub-pixel unit for Chrome and Firefox anti-alias
}

input[type=radio].wok-radio + label:before {
    content: "\f10c";
    letter-spacing: 5px;
}

input[type=radio].wok-radio:checked + label:before {
    content: "\f192";
    letter-spacing: 5px;
}

input[type=radio].wok-radio:focus + label:before,
input[type=checkbox].wok-checkbox:focus + label:before {
    text-shadow: 0px 0px 5px $input-border-focus;
}

input[type=checkbox].wok-checkbox + label,
input[type=radio].wok-radio + label {
    cursor: pointer;
    margin-right: 10px;
}
